{% extends 'EstocBundle:Client:clientHome.html.twig' %}

{% block content_client %}
    <div class="container-space home-container">
        <div class="clearfix pure-g">
            {{ form_start(form, { 'attr': {'class': 'profile-form'} }) }}
            <div class="pure-u-1-2">
                <div class="left-panel">
                    <div class="pure-g">
                        <div class="pure-u-1-2">
                            {{ form_row(form.clientProfile.firstname) }}
                        </div>
                        <div class="pure-u-1-2">
                            {{ form_row(form.clientProfile.lastname) }}
                        </div>
                    </div>
                    <div class="large-field">
                        {{ form_row(form.email) }}
                    </div>
                <hr/>
                    <div class="pure-g">
                        <div class="pure-u-1-2 margin-column-left">
                            {{ form_row(form.clientProfile.phone) }}
                        </div>
                        <div class="pure-u-1-2 margin-column-right">
                            {{ form_row(form.clientProfile.city) }}
                        </div>
                    </div>
                    <div class="pure-g">
                        <div class="pure-u-1-2">
                            {{ form_row(form.clientProfile.business) }}
                        </div>
                        <div class="pure-u-1-2 right">
                            <button id="edit_perfil" type="button" class="btn">MODIFICAR</button>
                        </div>
                    </div>
                <hr/>
                    <div class="large-field">
                        {{ form_row(form.clientProfile.address) }}
                    </div>
                    <div class="pure-g">
                        <div class="pure-u-1-2 margin-column-left">
                            {{ form_row(form.clientProfile.canton) }}
                        </div>
                        <div class="pure-u-1-2 margin-column-right">
                            {{ form_row(form.clientProfile.state) }}
                        </div>
                    </div>
                    <div class="pure-g">
                        <div class="pure-u-1-2">
                            {{ form_row(form.clientProfile.postalCode) }}
                        </div>
                        <div class="pure-u-1-2">
                        </div>
                    </div>
                </div>
            </div>
            <div class="pure-u-1-2">
                <div class="right-panel">
                    <div class="large-field align-center">
                        <span class="description">INGRESO DE DATOS PARA LA FACTURACIÓN</span>
                    </div>
                    <div class="large-field">
                        <p> </p>
                    </div>
                    <div class="large-field">
                        {{ form_row(form.clientProfile.razonSocial) }}
                    </div>
                    <div class="large-field">
                        {{ form_row(form.clientProfile.cedulaRuc) }}
                    </div>
                    <div class="large-field">
                        {{ form_row(form.clientProfile.comercialPhone) }}
                    </div>
                    <div class="large-field">
                        {{ form_row(form.clientProfile.paymentMethod) }}
                    </div>
                    <div class="large-field">
                        {{ form_row(form.clientProfile.contactName) }}
                    </div>
                    <div class="large-field">
                        <p><span class="description">SE NECESITA INTRODUCIR TODOS LOS CAMPOS</span></p>
                        <p>Al hacer click en registrarse acepta los <a class="modal menu_titulo" href="{{ path('terms') }}">términos y condiciones</a>, y politica de privacidad de ESTOC.</p>
                    </div>
                    <div class="large-field">
                        {{ form_widget(form.save) }}
                    </div>
                </div>
            </div>
            {{ form_end(form) }}
        </div>
    </div>
{% endblock %}

{% block stylesheets %}
    {{ parent() }}
    <link rel="stylesheet" href="{{ asset('js/colorbox/example5/colorbox.css') }}">
{% endblock %}

{% block javascripts %}
    {{ parent() }}
    <script type="text/javascript" src="{{ asset('js/colorbox/jquery.colorbox-min.js') }}"> </script>
    <script type="text/javascript">
        $(document).ready(function(){
            $(".modal").colorbox({iframe:true, width:"700", height:"400"});

            $('#edit_perfil').click(function(){
                $(".disabled_input").removeAttr('readonly');
            });
        });
    </script>
{% endblock %}